1. The Field of the Invention
This invention relates to managing cursor and window displays in a multiple monitor environment.
2. The Prior State of the Art
A typical computer system as shown in FIG. 1 includes a computer 300 having a central processing unit 304, an input/output unit 306 and memory 302 containing various programs used by the computer 300 such as an operating system 303 and one or more application programs 305. An end-user of the computer system communicates with computer 300 by means of various input devices (keyboard 320, mouse 310) which transfer information to the computer via input/output unit 306. The computer 300 replies to this input data, among other ways, by providing responsive output to the end-user, for example, by displaying appropriate text and images on the screen of a display monitor 330.
Operating systems often include a graphical user interface (xe2x80x9cGUIxe2x80x9d) by which the operating systems and any applications it may be running (e.g., a word-processing program) may communicate with an end-user. A commonly used GUI implementation employs a desktop metaphor in which the screen of the monitor is regarded as a virtual desktop. The desktop is an essentially two-dimensional working template area supporting various graphical objects, including one or more display regions. As shown in FIG. 2, information is displayed on the desktop 21 within display regions 23 (e.g., window, dialog box, pop-up menu, pull-down menu, drop-down list, icon), which are rectangular in shape. Each display region 23 may be dedicated to a specific application or to the operating system under which the applications are running. By manipulating a cursor 25 (such as with standard point and click and drag and drop techniques), an end-user can manage the display regions 23 as desired, for example, by creating new display regions or eliminating old ones, or by resizing or repositioning the display regions to fit the end-user""s needs. The end-user may xe2x80x9cactivatexe2x80x9d a particular display region and its associated application, for example, by xe2x80x9cclickingxe2x80x9d the cursor 25 when it appears within the desired region.
In a computer system using a single monitor 330 as shown in FIG. 1, a problem of screen clutter may occur when an end-user has a large number of display regions open on the monitor at the same time. Screen clutter tends to confuse the end-user and reduce his or her efficiency. Moreover, end-users of certain applications (desktop publishing, CAD/CAM/CAE, video conferencing, etc.) typically will want to be able to view and use two large display regions (e.g., an editing window and an output window) at substantially the same time, but often the most useful sizes of the two windows are too large to fit side-by-side on a single monitor.
To alleviate this problem, a computer system such as that shown in FIG. 3 having two monitors 330 and 332 has been used. In the multiple monitor system of FIG. 3, the combination of the monitor spaces (two in the case shownxe2x80x94one monitor space 41 corresponding to monitor 330 and a second monitor space 43 corresponding to monitor 332) may be treated as a single, contiguous virtual desktop 45 as shown in FIG. 4. Through appropriate cursor manipulations, an end-user may move objects, such windows A, B, C, D and cursor 25, back and forth between the two monitor spaces 41 and 43 or may even position one of these objects (e.g., window C in FIG. 4) so that it spans the two monitor spaces.
In one aspect of the invention, a computer having a display engine displays a window across multiple monitor spaces by determining that a display window that appears entirely within a first monitor space is to be moved or resized so that a first portion of the display window remains in the first monitor space and a second portion of the display window appears in a second monitor space. The first portion of the display window is displayed in the first monitor space by performing a bit block transfer operation, and the second portion of the display window in the second monitor space by passing the second portion of the display window through the display engine. If, however, the second monitor space has substantially the same color characteristics as the first monitor, both portions of the display window are displayed by performing a bit block transfer operation.
Windows that are moved to span monitor boundaries are re-drawn in an intelligent and efficient manner. The portion of the window that remains in the same monitor space is redrawn by moving a block of bits from one portion to another of the frame buffer for that monitor. Only the portion of the window that appears on a different monitor is xe2x80x9crepaintedxe2x80x9d from scratch. This reduces the number of necessary pixel calculations while maintaining the color characteristics of the various monitors being used.
In another aspect of the invention, a cursor image is displayed in one of multiple available monitor spaces upon an event being generated in response to movement of an input device, for example, a mouse. While the event is pending, a new position for the cursor image is determined based on an old position of the cursor image and the movement of the input device. If the new position of the cursor image is on a different one of the monitor spaces than the old cursor image, then the cursor image is displayed at its new position if a process running in the computer is not relying on the old position of the cursor image. Otherwise, an operation is placed in a queue to display the cursor image at its new position after the event has lapsed. Subsequently, the cursor image is displayed at its new position based on a queue of pending cursor image moves. In any event, all pending cursor image moves are performed before the applications are notified of the moves.
In one aspect of the invention, objects (e.g. a cursor image, a window or other display region) are displayed in one of multiple monitor spaces by comparing a position of the object with a position of each of the monitor spaces. A monitor space is chosen from among the multiple monitor spaces based on a result of the comparison, and the object is displayed in the chosen monitor space. If the object is a cursor image, for example, the comparison may be based on a squared distance between the position of the cursor and the positions of each of the monitor spaces. The cursor image may be displayed in the monitor space (for example, at a point on the edge of the monitor space) that has the smallest squared distance between it and the cursor.
Alternatively, the comparison may be accomplished by establishing a bounding rectangle for the monitor spaces by determining their union, and then comparing the position of the cursor with a position of the bounding rectangle. The cursor""s position is moved to a point within the bounding rectangle if the comparing determines that the cursor was at a position outside of the bounding rectangle. The cursor image may be displayed in the monitor space that has a closest Euclidean distancexe2x80x94the length of a hypothetical line drawn from the cursor to the monitor space such that the line is perpendicular to the edge of the monitor spacexe2x80x94between the monitor space and the cursor.
If the object is a window or other display region (e.g., dialog box, pop-up menu, pull-down menu), the comparison may be based on an area of overlap between the display region and each of the available monitor spaces. In that case, the monitor space that has a largest area of overlap with the display region is chosen for display. If no monitor space has an area of overlap with the display region, then the primary display, determined at the start up of the computer system, may be chosen. Alternatively, the monitor space containing the largest portion of surface area of the currently active window may be chosen. Once chosen, the window or other display region is moved so that it appears entirely within the chosen monitor space.
Positioning of display regions may be used to decide in which monitor space a minimized window should be maximized in response to input from the end-user. In that case, the position of a prior non-minimized state of the window is used in the overlap comparison, and the window may be maximized in the monitor space that contains the largest area of overlap with the window under consideration when it was in its prior non-minimized state.
Advantages of this invention may include one or more of the following. The techniques described here provide an end-user with a GUI that behaves and responds in a predictable and useful manner even if the GUI spans multiple monitor spaces. The cursor image always remains visible on exactly one monitor in a position that the end-user would most likely expect in response to the mouse being moved.
Display windows are positioned within a single monitor space so that the end-user can readily view and read the information displayed therein. Where appropriate, several Windows(copyright) operations (e.g., switching window, Print Screen, maximization, etc.) are directed towards a single predictable monitor space. In most cases, this monitor will be the one that is most likely for the end-user to presently be viewing. Windows are maximized onto a single monitor space in a manner that their edges do not spill over into an adjacent monitor space. The end-user is prevented from being able to reposition a window such that its title bar is entirely off-screen and thus inaccessible.
Because of the manner in which the cursor and display windows (and other display regions) are handled in a multiple monitor environment, the composite desktop need not itself be rectangular. Rather, the individual monitor spaces that make up the desktop may be positioned adjacent to one another in a manner that results in an irregularly shaped (i.e., non-rectangular) composite desktop.
Other advantages and features will become apparent from the following description, including the drawings and claims.
The methods and mechanisms described here are not limited to any particular operating system or hardware configuration, but rather they may find applicability in any computing or processing environment that uses multiple output devices.
The techniques described here may be implemented in hardware or software, or a combination of the two. Preferably, the techniques are implemented in computer programs executing on programmable computers that each include a processor, a storage medium readable by the processor (including volatile and non-volatile memory and/or storage elements), at least one input device, and two or more output devices. Program code is applied to data entered using the input device to perform the functions described and to generate output information. The output information is applied to one or more output devices.
Each program is preferably implemented in a high level procedural or object oriented programming language to communicate with a computer system. However, the programs can be implemented in assembly or machine language, if desired. In any case, the language may be a compiled or interpreted language.
Each such computer program is preferably stored on a storage medium or device (e.g., CD-ROM, hard disk or magnetic diskette) that is readable by a general or special purpose programmable computer for configuring and operating the computer when the storage medium or device is read by the computer to perform the procedures described in this document. The system may also be considered to be implemented as a computer-readable storage medium, configured with a computer program, where the storage medium so configured causes a computer to operate in a specific and predefined manner.